import {reqGetCenterInfo} from "@/api";
//Home模块
const state = {
    centerInfo: {}
}

const actions = {
    async getCenterInfo({commit}, {page, limit}) {
        let result = await reqGetCenterInfo(page, limit)
        if (result.code === 200) {
            commit('GETCENTERINFO', result.data)
        }
    },
}

const mutations = {
    GETCENTERINFO(state, centerInfo) {
        state.centerInfo = centerInfo
    }
}

const getters = {}//为了简化仓库中的数据

export default {
    namespaced: true,
    state,
    actions,
    mutations,
    getters
}

